<?php

require_once '../../config.php';
require_once '../../functions.php';


books_get_current_user();

$netbook = book_fetch_all("select * from netbook");

function add(){
    if(empty($_POST['nick'])){
        $GLOBALS['message']="请填写昵称的信息";
        return;
    }
    if(empty($_POST['content'])){
        $GLOBALS['message']="请填写昵称";
        return;
    }
    $nick = $_POST['nick'];
    $content = $_POST['content'];
    $date = date('Y-m-d H:i:s' ,time());
    $row = book_execute("insert into netbook values (null,'{$nick}','{$content}','{$date}')");

}

if($_SERVER['REQUEST_METHOD']==='POST'){
    add();
}


?>
<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Common &laquo; Admin</title>
    <link rel="stylesheet" href="/static/assets/vendors/bootstrap/css/bootstrap.min.css">
    <link rel="stylesheet" href="/static/assets/css/base.css">
    <link rel="stylesheet" href="/static/assets/css/index.css">
    <link rel="stylesheet" href="/static/assets/vendors/nprogress/nprogress.css">
    <script src="/static/assets/vendors/jquery/jquery.min.js"></script>
    <script src="/static/assets/vendors/bootstrap/js/bootstrap.min.js"></script>
    <script src="/static/assets/vendors/nprogress/nprogress.js"></script>
    <style>
        * {
            margin: 0;
            padding: 0;
        }
        li {
            list-style-type: none;
            padding: 5px 0;
            font-size: 16px;
            border-bottom: 1px dashed #ccc;
        }
      .person {
        margin-top:15px;
        width:1200px;
        height:600px;
        background-color: white;
        padding: 0 100px;
        border-radius: 5px;
        background:w;
        font-family: "全新硬笔行书简";
        font-size: 25px;

      }
      .speak {
        width: 200px;
        height: 200px;
        background-color: yellow;
        text-align: center;
        margin: 30px auto 0;
        border-radius: 50%;
        box-shadow: 0px 0px 15px rgba(0, 0, 0, #ccc);
        overflow: hidden;
      }
      .speak img {
          width: 100%;
          height: auto;
      }
      table {
          width: 300px;
          height: 300px;
      }
      .person_conn {
        height: 200px;
        display: flex;
      }
      .per_a {
          width: 300px;
          padding: 20px 20px;
          border: 1px solid #ccc;
      }
      .per_b {
        flex: 1;
        padding: 25px 15px;
      }
      .per {
          padding: 20px 250px;
      }
    </style>
</head>

<body>
    <script>
        NProgress.start()
    </script>
    <!-- 导航栏 -->
    <?php include '../inc/navbar.php'; ?>

    <div class="container person">
        <div class="speak">
           <img src="/static/assets/img/default.png" alt="">
        </div>
        <div class="person_conn">
            <div class="per_a">
                <li>性别:男</li>
                <li>爱好:嗯，挺多的</li>
                <li>想法: 这梦，应该可以，溜</li>
            </div>
            <div class="per_b">
                <h3>说点什么</h3>
                <span>本网站设计在于图书分享，致力于最优秀的图书信息<br>
                    只为你满意，秀出你最得意的评论<br>
                    若是有什么侵权行为，请于我联系，我立即改正<br>
                </span>
            </div>

        </div>
        <div class="per">
            <h3>联系：<a>1751749292@qq.com</a></h3>
        </div>

    </div>

    <script>
        $('.collapse').collapse()
    </script>
    <script>
        NProgress.done()
    </script>
</body>

</html>